package com.sztx.pay.center.rpc.api.domain;

import java.io.Serializable;

@SuppressWarnings("serial")
public class ConfirmOrderRequest implements Serializable {
	/**
	 * 商户的userId
	 * <br>是否必输: Y
	 */
	protected String userId;
	
	/**
	 * 结算金额（单位为分）
	 * <br>是否必输: Y
	 */
	protected long amount;
	/**
	 * 支付订单号
	 */
	protected String tradeOrderId;
	/**
	 * 业务订单号
	 */
	protected String outOrderId;
	/**
	 * 备注
	 */
	protected String remark;
	public String getUserId() {
		return userId;
	}
	public void setUserId(String userId) {
		this.userId = userId;
	}
	public long getAmount() {
		return amount;
	}
	public void setAmount(long amount) {
		this.amount = amount;
	}
	public String getTradeOrderId() {
		return tradeOrderId;
	}
	public void setTradeOrderId(String tradeOrderId) {
		this.tradeOrderId = tradeOrderId;
	}
	public String getOutOrderId() {
		return outOrderId;
	}
	public void setOutOrderId(String outOrderId) {
		this.outOrderId = outOrderId;
	}
	public String getRemark() {
		return remark;
	}
	public void setRemark(String remark) {
		this.remark = remark;
	}
	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result + (int) (amount ^ (amount >>> 32));
		result = prime * result
				+ ((outOrderId == null) ? 0 : outOrderId.hashCode());
		result = prime * result
				+ ((tradeOrderId == null) ? 0 : tradeOrderId.hashCode());
		result = prime * result + ((userId == null) ? 0 : userId.hashCode());
		return result;
	}
	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		ConfirmOrderRequest other = (ConfirmOrderRequest) obj;
		if (amount != other.amount)
			return false;
		if (outOrderId == null) {
			if (other.outOrderId != null)
				return false;
		} else if (!outOrderId.equals(other.outOrderId))
			return false;
		if (tradeOrderId == null) {
			if (other.tradeOrderId != null)
				return false;
		} else if (!tradeOrderId.equals(other.tradeOrderId))
			return false;
		if (userId == null) {
			if (other.userId != null)
				return false;
		} else if (!userId.equals(other.userId))
			return false;
		return true;
	}
	

}
